#define _CRT_SECURE_NO_WARNINGS

#include <stdio.h>

int main()
{
	int n = 0;
	int s = 0;
	int g = 0;
	int g2 = 0;
	float s_sum = 0;
	float g_sum = 0;
	float ret = 0;

	scanf("%d", &n);

	int i = 0;
	for (i = 1; i <= n; i++)
	{
		scanf("%d %d", &s, &g);
		g2 = (g - 50) / 10;
		if (g2 < 0)
			g2 = 0;
		s_sum += s * g2;
		g_sum += s;
	}

	ret = s_sum / g_sum;
	printf("%.1f", ret);
	return 0;
}